<?php

class Player_Piece
{
    private $_name = '';

    public function __construct($name)
    {
        $this->setName($name);
    }

    public function setName($name)
    {
        $this->_name = $name;
    }

    public function getName()
    {
        return $this->_name;
    }

    public function move($spaces, $space)
    {
        for ($i = 0; $i < $spaces; $i++) {
            $space = $space->next();
        }

        return $space;
    }
}
